<h1>{LANG:EDIT_MENU}</h1>
<p>{VAR:MESSAGE}</p>
<form action="{VAR:URL}" method="POST">
  <h2>{LANG:EDITMENU}</h2>
  {VAR:EDITABLEMENU}
  <input name="save" type="submit" value="{LANG:SAVE}"/>
  <h2>{LANG:ENTRY_ADD}</h2>
  <table>
    <tr>
	  <td style="width:100px;">{LANG:TEXT}:</td>
	  <td><input name="newtitle" style="width:200px;" /></td>
	</tr>
	<tr>
	  <td>{LANG:TYPE}:</td>
	  <td>
	    <script language="javascript">
		  function typeSelected(){
			document.getElementsByName('newPage')[0].style.visibility ='hidden';
			document.getElementsByName('newurl')[0].style.visibility ='hidden';
			document.getElementsByName('newMenu')[0].style.visibility  ='hidden';
		    if(document.getElementById('type').selectedIndex == 0){
			  document.getElementsByName('newPage')[0].style.visibility ='visible';
			  document.getElementById('newLabel').innerHTML = '{LANG:PAGE}:';
			}
			else if(document.getElementById('type').selectedIndex == 1){
			  document.getElementsByName('newurl')[0].style.visibility  ='visible';
			  document.getElementById('newLabel').innerHTML = 'Url:';
			}
			else{
			  document.getElementsByName('newMenu')[0].style.visibility ='visible';
			  document.getElementById('newLabel').innerHTML = '{LANG:MENU}:';
			}
		  }
		</script>
        <select id="type" name="type" onChange="typeSelected()" style="width:200px;">
          <option value="0">{LANG:PAGE_INTERNAL}</option>
          <option value="1">{LANG:PAGE_EXTERNAL}</option>
          <option value="2">{LANG:MENU}</option>
        </select>
	  </td>
	  </tr>
	  <tr>
	    <td><span id="newLabel">{LANG:PAGE}</a>:</td>
        <td>
		  <input name="newurl" value="http://" style="width:200px;visibility:hidden" />
		  {VAR:MENUSELECTOR}
		  {VAR:PAGESELECTOR}
		</td>
	  </tr>
  </table>
  <input name="add" type="submit" value="Hinzuf&uuml;gen"/>
</form>